<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8" isELIgnored="false"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="s" uri="http://www.springframework.org/tags"%>
<script type="text/javascript">
	$(function() {
		// alert('hello jQuery!');
	});
</script>
<div class="table-responsive">
	<table class="table table-bordered table-striped table-hover">
		<caption><s:message code="views.form.user.caption" /></caption>
		<thead>
			<tr>
				<th><s:message code="model.user.no" /></th>
				<th><s:message code="model.user.name" /></th>
				<th><s:message code="model.user.email" /></th>
				<th><s:message code="model.user.telephone" /></th>
				<th><s:message code="views.label.operations" /></th>
			</tr>
		</thead>
		<tbody>
			<c:forEach items="${users}" var="u" varStatus="s">
				<tr>
					<td>${s.count}</td>
					<td>${u.name}</td>
					<td>${u.email}</td>
					<td>${u.telephone}</td>
					<td>
					   <a href="users/${u.id}"><s:message code="views.label.details" /></a> 
					   <a href="users/edit/${u.id}"><s:message code="views.label.edit" /></a> 
                       <a href="users/${u.id}.json">JSON</a>
                       <a href="users/${u.id}.xml">XML</a>
				    </td>
				</tr>
			</c:forEach>
		</tbody>
	</table>
</div>
<p>
	<a href="users/new"><s:message code="views.label.new" /></a>
</p>
